]> git.r.bdr.sh - rbdr/captura/blobdiff - Captura/Core Extensions/CVImageBuffer+cgImage.swift
Format the code
[rbdr/captura] / Captura / Core Extensions / CVImageBuffer+cgImage.swift
index eb62e7aefeffd26ff7ee75e767d2c94c687443cf..ba98855dbaca54c9ef77621b43bb7b5d05a91022 100644 (file)
@@ -18,19 +18,20 @@ import Foundation
 import ReplayKit
 
 extension CVImageBuffer {
-  
+
   private static let contextQueue = DispatchQueue(label: "com.example.contextQueue")
   static let sharedContext: CIContext = {
-          return CIContext()
+    return CIContext()
   }()
-  
+
   var cgImage: CGImage? {
     var result: CGImage?
     CVImageBuffer.contextQueue.sync {
       let ciImage = CIImage(cvImageBuffer: self)
       let width = CVPixelBufferGetWidth(self)
       let height = CVPixelBufferGetHeight(self)
-      result = CVImageBuffer.sharedContext.createCGImage(ciImage, from: CGRect(x: 0, y: 0, width: width, height: height))
+      result = CVImageBuffer.sharedContext.createCGImage(
+        ciImage, from: CGRect(x: 0, y: 0, width: width, height: height))
     }
     return result
   }